package com.logos.musicframe.listener;

import com.logos.musicframe.entity.SongsLiked;
import lombok.extern.slf4j.Slf4j;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

/**
 * @author logos
 * date 2025/6/18 13:54
 * @version v1.0
 * @Package com.logos.musicframe
 */
@Component
@Slf4j
public class TestListener {

    @RabbitListener(queues = "simple.queue")
    public void listenSimpleQueue2(String msg) {
        log.info("消费者simple.queue接收到消息：{}", msg);
    }

    @RabbitListener(queues = "simple.queue")
    public void listenSimpleQueue(SongsLiked songsLiked) {
        log.info("消费者simple.queue接收到消息：{}", songsLiked);
    }

    @RabbitListener(queues = "simple.queue2")
    public void listenSimpleQueue2(SongsLiked songsLiked) {
        log.info("消费者simple.queue2接收到消息：{}", songsLiked);
    }
}
